package com.sscw.task.enums;

/**
 * @Author: sunxuzong
 * @Date: 2024/07/19
 */
public enum LabelTypeEnum {
    sign(1,"签到"),
    recharge(2,"充值"),
    month_card(3,"月卡"),
    week_card(4,"周卡"),
    redemption_code(5,"兑换码"),
    activity(6,"活动"),
    redemption(7,"松子兑换松果"),
    challenge(8,"挑战"),
    rank_list(9,"排行榜"),
    pine(10,"松树"),
    play_pay(11,"游戏支出"),
    rename(12,"改名"),
    reward(13,"赏金"),
    invite_friends(14,"邀请好友"),
    accept_invite(15,"接受邀请"),
    occupy(16,"包机"),
    daily_task(17,"每日任务"),
    task(18,"长期任务"),
    upgrade(19,"升级赠送"),
    admin(20,"后台充值")
    ;

    private Integer code;

    private String desc;

    LabelTypeEnum(Integer code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public static LabelTypeEnum getByCode(Integer code){
        for (LabelTypeEnum enums : LabelTypeEnum.values()){
            if (enums.getCode().equals(code)){
                return enums;
            }
        }
        return  null;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }
}
